
<script type="text/javascript">
 			$(function(){
 	 			$('#dateon').datepicker({changeYear: true,changeMonth:true ,showButtonPanel: true,yearRange:"150:2020"});
 	 			$('#dateoff').datepicker({changeYear: true,changeMonth:true ,showButtonPanel: true,yearRange:"150:2020"});
 			});
 		</script>
<form action="<?php echo $this->url(array("action"=>"edit")) ?>"
	method="post" id="insert-form" enctype="multipart/form-data">
   <?php $n = $this->News?>
                <div class="form-left">
		<label for="Title">Tiêu đề: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<input type="text" name="Title" class="txt" id="CatName"
			value="<?php echo $n->TITLE?>" />
	</div>

	<div class="form-left">
		<label for="Position">Danh mục cha: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<select name="Cat">
			<option value="0">Không chọn</option>
                    <?php
																				
foreach ( $this->allCat as $cat ) {
																					echo "<option value='" . $cat ["ID"] . "'>" . $cat ["CAT_NAME"] . "</option>";
																				}
																				?>
                    </select>
                    </div>
		<div class="form-left">
			<label for="Tags">Tags: <span class="required">*</span></label>
		</div>
		<div class="form-right">
			<input type="text" name="Tags" class="txt" id="Tags" value="<?php echo $n->TAGS?>"/>
		</div>
	<div class="form-left">
		<label for="Desc">Mô tả: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<input type="text" name="Desc" class="txt" id="Desc"
			value="<?php echo $n->SHORT_CONTENT?>" />
	</div>

	<script type="text/javascript"
		src="<?php echo $this->baseUrl()?>/public/ckeditor/ckeditor.js"></script>
	<script type="text/javascript"
		src="<?php echo $this->baseUrl()?>/public/ckeditor/_samples/sample.js"></script>

	<div class="form-left">
		<label for="Content">Nội dung: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<textarea name="Content" id="editor" class="txt editor" cols="100"
			rows="200" id="Content"><?php echo $n->LONG_CONTENT?></textarea>
		<script type="text/javascript">CKEDITOR.replace( 'editor' );</script>

	</div>

	<div class="form-left">
		<label for="PImg">Hình ảnh: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<input type="file" name="PImg" class="txt" id="PImg" />
                    <?php echo $this->errImg?>
                </div>
	<div class="form-left">
		<label for="textImg">Link ảnh: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<input type="text" name="textImg" class="txt" id="textImg"
			value="<?php echo $n->IMG?>" />
	</div>

	<div class="form-left">
		<label for="stt">Trạng thái: <span class="required">*</span></label>
	</div>
	<div class="form-right">
		<select name="Stt" id="theme">
                        <?php if($n->STATUS == 1):?>
                        <option value="1" selected="selected">Kích hoạt</option>
			<option value="0">Không kích hoạt</option>
                        <?php else :?>
                        <option value="1">Kích hoạt</option>
			<option value="0" selected="selected">Không kích hoạt</option>
                        <?php endif;?>
                    </select>
	</div>

	<div class="clear" style="text-align: right; width: 372px">
		<input type="button" value="Go Back" style="float: right"
			onclick="javascript:history.go(-1);" /> <input type="submit"
			value="Save" style="float: right" />
	</div>
</form>
<script type="text/javascript"
	src="<?php echo $this->baseUrl()?>/public/js/tablesort.js"></script>
<script type="text/javascript"
	src="<?php echo $this->baseUrl()?>/public/js/jquery.nyromodal-1.6.2.pack.js"></script>
<script type="text/javascript" charset="utf-8"
	src="<?php echo $this->baseUrl()?>/public/js/jquery.uniform.min.js"></script>